package com.ironone.mediaplayerdemo;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class SecondActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.second_activity);

		Button previousButton = (Button) findViewById(R.id.previous_button);

		previousButton.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				Intent i = new Intent(SecondActivity.this, MainActivity.class);
				startActivity(i);
				overridePendingTransition(R.anim.slide_right_to_middle, R.anim.slide_middle_to_left);
				finish();
			}
		});
	}
}
